Skip to content

feat: emit manifest.json for PWA support#60

Open
ilfroloff wants to merge 1 commit intoswingmx:masterfrom
ilfroloff:feat/pwa-manifest
Open

feat: emit manifest.json for PWA support#60
ilfroloff wants to merge 1 commit intoswingmx:masterfrom
ilfroloff:feat/pwa-manifest

Conversation

@ilfroloff
Copy link
Copy Markdown

Why

The VitePWA plugin defaults to generating manifest.webmanifest.
Browsers and the Swing Music backend both look for /manifest.json, so
the default filename causes a 404 in production and prevents install
prompts from firing.

What this PR does

  1. Sets manifestFilename: "manifest.json" in vite.config.ts so
    VitePWA writes the manifest at /manifest.json (both in the dev
    server and in the production build output).

  2. Removes public/site.webmanifest – this was an empty placeholder
    with incorrect icon paths. It is superseded by the manifest that
    VitePWA generates from the plugin configuration.

Testing

yarn dev
curl -I http://localhost:5173/manifest.json
# → HTTP/1.1 200 OK
# → Content-Type: application/manifest+json

Related

Companion PR in swingmx/swingmusic adds a /manifest.json route to
the Flask backend and a bundled fallback manifest for server-only
installs.

- Set manifestFilename to "manifest.json" in the VitePWA plugin so the
  build outputs /manifest.json instead of /manifest.webmanifest.
  Browsers and the Swing Music server both expect the .json extension.
- Remove public/site.webmanifest (empty placeholder with wrong icon
  paths; superseded by VitePWA-generated manifest.json).
@CLAassistant
Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Illia Fralou seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants